﻿@page "/Pies/Pushout"
@using LiveChartsCore
@using LiveChartsCore.SkiaSharpView.Blazor
@using LiveChartsCore.SkiaSharpView.Extensions

<PieChart
	Series="Series">
</PieChart>

@code {
    private ISeries[] Series { get; set; }

    protected override void OnInitialized()
    {
        Series = new[] { 6, 5, 4, 3, 2 }.AsPieSeries((value, series) =>
        {
            // pushes out the slice with the value of 6 to 30 pixels.
            if (value != 6) return;

            series.Pushout = 30;
        });
    }
}
